class WaitMakeFriendRequisition < MakeFriendRequisition
  
  #该谷友是否已经被我申请
  def self.has_been_for_friend(active_id, passive_id)
    WaitMakeFriendRequisition.first :conditions => ["active_valleyer_id = ? and passive_valleyer_id = ?", active_id, passive_id]
  end

  #所有对我的申请
  def self.wait_me_to_confirm(passive_id)
    WaitMakeFriendRequisition.all :conditions => ["passive_valleyer_id = ?", passive_id],
      :order => "created_at desc"
  end

end